package com.headwind.service.impl;

import com.headwind.entity.HwMood;
import com.headwind.mapper.HwMoodRepository;
import com.headwind.service.HwMoodService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * @author : Headwind
 * @version : 1.0
 * @date : Created in 2020/8/10
 * @description : 说说实现类
 */
@Service
public class HwMoodServiceImpl implements HwMoodService {
    private final HwMoodRepository hwMoodRepository;

    @Autowired
    public HwMoodServiceImpl(HwMoodRepository hwMoodRepository) {
        this.hwMoodRepository = hwMoodRepository;
    }

    @Transactional()
    @Override
    public HwMood save(HwMood hwMood) {
        return hwMoodRepository.save(hwMood);
    }
}
